var AllOptions = {
    createOption2(labelList, dataList) { //省内疫苗生产企业经济现状
        return {
            color: ['#05D187', '#29A1F7', '#FF9722', '#EB3432'],
            grid: {
                left: 80,
                top: 50,
                bottom: 40,
                right: 40
            },
            title: {
                text: '单位：亿元',
                textStyle: {
                    color: '#fff',
                    fontSize: 16
                },
                left: 10
            },
            legend: {
                show: true,
                top: 0,
                right: 40,
                zlevel: 10,
                icon: 'roundRect',
                itemWidth: 20, // 设置宽度
                itemHeight: 14, // 设置高度
                itemGap: 20, // 设置间距
                textStyle: {
                    color: '#fff',
                    fontSize: 16
                },
            },
            xAxis: {
                type: 'category',
                data: labelList,
                axisLabel: {
                    inside: false,
                    textStyle: {
                        color: '#fff',
                        fontSize: 16
                    },
                    interval: 0, //保证所有横向坐标数据全展示不隐藏
                    margin: 10 //刻度与坐标轴距离
                },
                axisTick: {
                    show: false
                },
                axisLine: {
                    show: true, //不显示y轴
                    symbol: ['none', 'arrow'],
                    symbolOffset: [0, 14],
                    lineStyle: {
                        color: '#67798f'
                    }
                },
                splitLine: {
                    show: true, //纵向网格线
                    lineStyle: {
                        color: ['#334c69']
                    }
                }
            },
            yAxis: {
                type: 'value',
                axisLabel: {
                    inside: false,
                    textStyle: {
                        color: '#fff',
                        fontSize: 16
                    },
                    // interval: 0,
                    margin: 20 //刻度与坐标轴距离
                },
                axisTick: {
                    show: false //不显示刻度
                },
                axisLine: {
                    show: true, //不显示y轴
                    symbol: ['none', 'arrow'],
                    symbolOffset: [0, 14],
                    lineStyle: {
                        color: '#67798f'
                    }
                },
                splitLine: {
                    show: false, //横向网格线
                    lineStyle: {
                        color: ['#334c69']
                    }
                },
                splitArea: {
                    show: true, //横向网格区域
                    areaStyle: {
                        color: ['rgba(0, 70, 255, 0.1)', 'rgba(5,39,75,0)']
                    }
                }
            },
            tooltip: {
                trigger: 'axis',
                axisPointer: { // 横坐标指示器
                    type: 'line',
                    lineStyle: {
                        color: 'rgba(0,0,0,0)'
                    }
                },
                // alwaysShowContent: true, //悬浮后一直显示
                // 自定义悬浮提示框内容（数据处理后加单位）
                backgroundColor: 'rgba(0,0,0,0)',
                formatter(params) { // params的个数等于折线的条数（对多条折线数据进行加单位，就需要遍历）
                    var relVal = '<div class="bg_2_tip" style="text-align:left;padding:20px 30px;font-size:14px "><span style="color:#fff;font-size:20px">' + params[0].name + '</span>' + (params[0] ? '<br><span class="color-blue-2">' + params[0].seriesName + '<span class="color-yellow-2 f20 pl10">' + params[0].value + '</span>亿元</span>' : '') + '' + (params[1] ? '<br><span class="color-blue-2">' + params[1].seriesName + '<span class="color-yellow-2 f20 pl10">' + params[1].value + '</span>亿元</span>' : '') + '' + (params[2] ? '<br><span class="color-blue-2">' + params[2].seriesName + '<span class="color-yellow-2 f20 pl10">' + params[2].value + '</span>亿元</span>' : '') + '' + (params[3] ? '<br><span class="color-blue-2">' + params[3].seriesName + '<span class="color-yellow-2 f20 pl10">' + params[3].value + '</span>亿元</span>' : '') + '</div>'
                    return relVal
                }
            },
            series: [{
                name: '累计产值',
                type: 'bar',
                data: dataList[0],
                barMaxWidth: '20',
                barGap: '0%',
            }, {
                name: '累计利润',
                type: 'bar',
                data: dataList[1],
                barMaxWidth: '20',
                barGap: '20%'
            }, {
                name: '当年产值',
                type: 'bar',
                data: dataList[2],
                barMaxWidth: '20',
                barGap: '20%'
            }, {
                name: '当年利润',
                type: 'bar',
                data: dataList[3],
                barMaxWidth: '20',
                barGap: '20%'
            }]
        }
    },
    createOption3(labelList, dataList) { //全省疫苗历年总体经济情况
        return {
            color: ['rgba(255, 41, 42, 1)', 'rgba(0, 198, 1, 1)'],
            grid: {
                left: 80,
                top: 50,
                bottom: 40,
                right: 40
            },
            title: {
                text: '单位：亿元',
                textStyle: {
                    color: '#fff',
                    fontSize: 16
                },
                left: 10
            },
            legend: {
                show: true,
                // top: 0,
                // right: 40,

                align: 'auto',
                zlevel: 10,
                // icon: 'image://',
                itemWidth: 20, // 设置宽度
                itemHeight: 14, // 设置高度
                itemGap: 20, // 设置间距
                textStyle: {
                    color: '#fff',
                    fontSize: 16
                },
            },
            data: [{
                    name: '产值',
                    icon: 'image://',
                },
                {
                    name: '利润',
                    icon: 'image://'
                }
            ],
            xAxis: {
                type: 'category',
                data: labelList,
                axisLabel: {
                    inside: false,
                    textStyle: {
                        color: '#fff',
                        fontSize: 16
                    },
                    interval: 0, //保证所有横向坐标数据全展示不隐藏
                    margin: 10 //刻度与坐标轴距离
                },
                axisTick: {
                    show: false
                },
                axisLine: {
                    show: true, //不显示y轴
                    symbol: ['none', 'arrow'],
                    symbolOffset: [0, 14],
                    lineStyle: {
                        color: '#67798f'
                    }
                },
                splitLine: {
                    show: true, //纵向网格线
                    lineStyle: {
                        color: ['#334c69']
                    }
                }
            },
            yAxis: {
                type: 'value',
                axisLabel: {
                    inside: false,
                    textStyle: {
                        color: '#fff',
                        fontSize: 16
                    },
                    // interval: 0,
                    margin: 20 //刻度与坐标轴距离
                },
                axisTick: {
                    show: false //不显示刻度
                },
                axisLine: {
                    show: true, //不显示y轴
                    symbol: ['none', 'arrow'],
                    symbolOffset: [0, 14],
                    lineStyle: {
                        color: '#67798f'
                    }
                },
                splitLine: {
                    show: false, //横向网格线
                    lineStyle: {
                        color: ['#334c69']
                    }
                },
                splitArea: {
                    show: true, //横向网格区域
                    areaStyle: {
                        color: ['rgba(0, 70, 255, 0.1)', 'rgba(5,39,75,0)']
                    }
                }
            },
            tooltip: {
                trigger: 'axis',
                axisPointer: { // 横坐标指示器
                    type: 'line',
                    lineStyle: {
                        color: 'rgba(0,0,0,0)'
                    }
                },
                // alwaysShowContent: true, //悬浮后一直显示
                // 自定义悬浮提示框内容（数据处理后加单位）
                backgroundColor: 'rgba(0,0,0,0)',
                formatter(params) { // params的个数等于折线的条数（对多条折线数据进行加单位，就需要遍历）
                    var relVal = '<div class="bg_2_tip" style="text-align:left;padding:20px 30px;font-size:14px "><span style="color:#fff;font-size:20px;">' + params[0].name + '</span>' + (params[0] ? '<br><span class="color-blue-2">' + params[0].seriesName + '<span class="color-yellow-2 f20 pl10">' + params[0].value + '</span>亿元</span>' : '') + '' + (params[1] ? '<br><span class="color-blue-2">' + params[1].seriesName + '<span class="color-yellow-2 f20 pl10">' + params[1].value + '</span>亿元</span>' : '') + '</div>'
                    return relVal
                }
            },
            series: [{
                name: '产值',
                type: 'line',
                data: dataList[0],
                // symbol: 'circle', //
                symbolSize: 12
            }, {
                name: '利润',
                type: 'line',
                data: dataList[1],
                symbolSize: 12
            }]
        }
    },
    createOption4(mapCityJson, dataList) { //地图

        var geoCoordMap = {}
        for (var i = 0; i < mapCityJson.features.length; i++) {
            var name = mapCityJson.features[i].properties.name
            geoCoordMap[name] = mapCityJson.features[i].properties.center
        }

        var convertData = function (data) {
            var res = [];
            for (var i = 0; i < data.length; i++) {
                res.push({
                    name: data[i].name,
                    value: data[i].coords.concat(data[i].value)
                })
            }
            return res;
        };
        echarts.registerMap('zj', mapCityJson); //为了实现阴影效果，所以叠加一层
        echarts.registerMap('zj1', mapCityJson);
        return {
            color: ['rgba(255, 41, 42, 1)', 'rgba(0, 198, 1, 1)'],
            grid: {},
            geo: {
                map: 'zj',
                label: {
                    emphasis: {
                        show: false
                    }
                },
                itemStyle: {
                    normal: {
                        areaColor: '#323c48',
                        borderColor: '#111'
                    },
                    emphasis: {
                        areaColor: '#2a333d'
                    }
                }
            },
            series: [{
                    left: 50,
                    right: 30,
                    top: 20,
                    bottom: 10,
                    name: '',
                    type: 'map',
                    mapType: 'zj', // 自定义扩展图表类型
                    itemStyle: {
                        normal: {
                            label: {
                                show: true,
                                color: '#fff'
                            },
                            areaColor: '#0a0d49',
                            borderWidth: 5,
                            borderColor: '#03c0ff',
                            shadowBlur: 20,

                            shadowColor: '#03c0ff'
                        },
                        emphasis: {
                            label: {
                                show: true
                            }
                        }
                    }
                }, {
                    left: 50,
                    right: 30,
                    top: 20,
                    zlevel: 12,
                    z: 12,
                    bottom: 10,
                    name: '',
                    type: 'map',
                    mapType: 'zj1', // 自定义扩展图表类型
                    itemStyle: {
                        normal: {
                            label: {
                                show: true,
                                color: '#fff',
                                fontSize: 16
                            },
                            areaColor: '#0a0d49',
                            borderWidth: 1,
                            borderColor: '#13358e',

                        },
                        emphasis: {
                            label: {
                                show: true
                            }
                        }
                    }
                },
                {
                    name: '标记',
                    type: 'scatter',
                    coordinateSystem: 'geo',
                    data: convertData(dataList),
                    // geoIndex: 20,//这个值不能要
                    zlevel: 18,
                    z: 18,
                    symbolSize: [28, 34],
                    symbol: "image://",
                    dimension: 0, //制定第一个数据（value）
                    seriesIndex: 0, //重要，制定第一组数据作为关联项，不设置时波纹小圆圈的颜色会跟随这个颜色

                }

            ]
        }
    }

}